<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags" %>
<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<meta name="viewport" content="width=device-width, minimum-scale=1, maximum-scale=1">
	<title></title>
	<link rel="stylesheet" href="../jquery/jquery.mobile-1.0a4.1.min.css" />
	<link rel="stylesheet" href="../css/site_style.css"/>
	<script type="text/javascript" src="../jquery/jquery-1.5.2.min.js"></script>
    <script type="text/javascript" src="../jquery/jquery.mobile-1.0a4.1.min.js"></script>
    <script type="text/javascript" src="site_maint.js"></script>

</head> 
<body>
<div data-role="page" id="album-list">

	<div id="header" data-role="header" data-theme="b">
		<s:if test="#session.login_user.category!=null">
	        	欢迎进入站点管理页面
		 </s:if>
	 	<s:else>
	         	欢迎进入<s:property value="site.category.categoryName"/>管理页面
	      </s:else>
			
	</div><!-- /header -->

	<div data-role="content">
		
		<ul data-role="listview" data-split-icon="gear" data-split-theme="d" data-filter="true" data-inset="true">
		 	 <s:if test="#session.login_user.category!=null">
	        	<a  onclick="location='show_add.action'" data-icon="Plus" data-iconpos="notext" data-role="button" style="margin: 2px;float: right;" >添加</a> 
			 </s:if>
	 		<s:else>
	         <a  onclick="location='show_add.action?site.category.categoryNo=<s:property value="site.category.categoryNo" />'" data-icon="Plus" data-iconpos="notext" data-role="button" style="margin: 2px;float: right;" >添加</a> 
	     	 </s:else>
			
			
			<s:if test="#session.login_user.category!=null">
	        	<a  onclick="location='../member/member_main.jsp'" data-role="button" data-icon="home" data-iconpos="notext" style="margin: 2px;" >回退</a>
	         </s:if>
	         <s:else>
	         	<a id="home"  data-role="button" data-icon="home" data-iconpos="notext" style="margin: 2px;" >回退</a>
	          </s:else>
			
			
			<s:iterator value="siteList" >
			<li>
			    
				<a onclick="location='find.action?command=modify&site.siteNo=<s:property value="siteNo" />&site.category.categoryNo=<s:property value="site.category.categoryNo" />'" >

				<img src="../upload/<s:property value="photoName"/>" width="80" height="80" onclick="location='find.action?command=modify&site.siteNo=<s:property value="siteNo" />&site.category.categoryNo=<s:property value="site.category.categoryNo" />'"/>
				<h3><s:property value="siteName"/></h3>
				<p><s:property value="siteDesc" /></p>
				</a>
				<a onclick="location='find.action?command=delete&site.siteNo=<s:property value="siteNo" />&site.category.categoryNo=<s:property value="site.category.categoryNo" />'"  data-role="button" data-iconpos="top" data-icon="delete">删除</a>
			</li>
			</s:iterator>
		</ul>
	</div><!-- /content -->
</div><!-- /page -->

</body>
</html>
